/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package pkg16b_eca;

import java.util.logging.Level;
import java.util.logging.Logger;
import pkg16b_eca.data.validate.DateTime;

/**
 *
 * @author Tabascomang
 */
public class GraphicRefresher implements Runnable {

    private final ECAFunctions ECAF;
    private final ECA ECAForm;

    public GraphicRefresher(ECAFunctions B, ECA eca) {
        ECAF = B;
        ECAForm = eca;
    }

    @Override
    public void run() {
        boolean ProgramRunning = true;
        System.out.println(DateTime.getTime() + ": GraphicRefresher Thread is now running");

        while (ProgramRunning == true) {
            //boolean isNameSelected = ECAF.isNameSelected;
                ECAForm.RepaintThisShit();
            try {
                Thread.sleep(500);
            } catch (InterruptedException ex) {
                Logger.getLogger(GraphicRefresher.class.getName()).log(Level.SEVERE, null, ex);
            }

        }

    }
}
